#ifndef SOCKTHREAD_H
#define SOCKTHREAD_H

#include <QThread>
#include <QTcpSocket>
#include <QFile>

#include "../mime/freedesktopmime.h"
#include "rctcpsocket.h"
#include "directory/plugdirectory.h"


class sockThread : public QThread
{
    Q_OBJECT
public:
    sockThread(int socketDescriptor, QObject *parent, QString directory, int upLimit, int dwLimit);
    void run();

signals:
    void error(QTcpSocket::SocketError socketError);

protected:
    void readRequest();
    void writeResponse();

private:
    //QTcpSocket *tcpSocket;
    int socketDescriptor;
    QString text;
    QString directory;
    int upLimit;
    int dwLimit;
};

#endif // SOCKTHREAD_H
